package com.rc.pojo.po.table;

import com.mybatisflex.core.query.QueryColumn;
import com.mybatisflex.core.table.TableDef;

// Auto generate by mybatis-flex, do not modify it.
public class QuestionTableDef extends TableDef {

    /**
     * 实体类。

 @author 27806
 @since 2024-06-29
     */
    public static final QuestionTableDef QUESTION = new QuestionTableDef();

    public final QueryColumn ID = new QueryColumn(this, "id");

    public final QueryColumn TYPE = new QueryColumn(this, "type");

    public final QueryColumn ILL_ID = new QueryColumn(this, "ill_id");

    /**
     * 题目内容
     */
    public final QueryColumn CONTENT = new QueryColumn(this, "content");

    public final QueryColumn PLANT_ID = new QueryColumn(this, "plant_id");

    public final QueryColumn QUE_INDEX = new QueryColumn(this, "que_index");

    public final QueryColumn CREATE_TIME = new QueryColumn(this, "create_time");

    public final QueryColumn UPDATE_TIME = new QueryColumn(this, "update_time");

    /**
     * 所有字段。
     */
    public final QueryColumn ALL_COLUMNS = new QueryColumn(this, "*");

    /**
     * 默认字段，不包含逻辑删除或者 large 等字段。
     */
    public final QueryColumn[] DEFAULT_COLUMNS = new QueryColumn[]{ID, TYPE, ILL_ID, CONTENT, PLANT_ID, QUE_INDEX, CREATE_TIME, UPDATE_TIME};

    public QuestionTableDef() {
        super("rc", "question");
    }

    private QuestionTableDef(String schema, String name, String alisa) {
        super(schema, name, alisa);
    }

    public QuestionTableDef as(String alias) {
        String key = getNameWithSchema() + "." + alias;
        return getCache(key, k -> new QuestionTableDef("rc", "question", alias));
    }

}
